package com.course.web.model;

import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.NotEmpty;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * Created by Justin on 2017/6/14.
 */
@Data
@EqualsAndHashCode(of = {"id"})
public class ClassMarkVM implements HasID {
    @Min(0)
    private int id;
    @NotEmpty
    private String student;
    @NotEmpty
    private String teacher;
    @NotEmpty
    private String task;
    @NotNull
    private Date date;
    @Range(min = 1, max = 5)
    private int mark1;
    @Range(min = 1, max = 5)
    private int mark2;
    @Range(min = 1, max = 5)
    private int mark3;
    @Range(min = 1, max = 5)
    private int mark4;
    @Range(min = 1, max = 5)
    private int mark5;
    @NotEmpty
    private String suggest;
    @NotEmpty
    private String comment;
    @NotEmpty
    private String message;
    @NotEmpty
    private String sugCn;
    @NotEmpty
    private String comCn;
}
